-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Experemental interoperation improvements #25
Experemental interoperation improvements #25
Conversation
Thank you @Drainful! Overall this looks good to me (but lets see what @rkoeninger has to say, he is more familiar than me with both Common Lisp and this port). Something I would change: prefix the new functions with |
…thub.com/Drainful/shen-cl into experemental_interoperation_improvements
That's a good idea. I have renamed them. Also, I had only tested with SBCL earlier, but now I realize that on my machine the CLISP implementation fails tests on chapter 13 with a segmentation fault on both my fork and the master branch, while the ECL implementation fails only on my fork while attempting to load the tests, saying that the |
@Drainful CLisp tests fail on master? Should probably open a separate issue for that including the specs of your machine so we can try to reproduce it. |
I created the issue: #26 |
@tizoc do travis-ci builds not trigger for PRs in this repo? |
@rkoeninger no idea what is going on, but I checked the logs here https://travis-ci.org/Shen-Language/shen-cl/requests and it says "abuse detected". Any idea what that means? could the test be taking too much time or using too much resources? |
I don't think the abuse metrics are made public but that seems possible. I ought to close this PR until I get the bugs sorted out. |
@Drainful I found this https://travis-ci.community/t/some-pr-are-not-analyzed-with-message-abuse-detected/1191 It seems that you registering and logging in to travis-ci.org (if you haven't ever done so in the past) would make you a "trusted" user to their system. |
Alright I registered with this github account. I'll try re-opening to trigger a travis build. EDIT: I have received the following notification on travis "The account Ipkcle has been flagged for potential abuse. Please contact support@travis-ci.com.". Either there is something else about the PR triggering the abuse warning, or perhaps my account was too new. I'll contact them. |
@Drainful push another commit to trigger a build |
Hmmm... still saying abuse dectected. I'll try pushing a commit... Doesn't like me either. Repo must be flagged. |
I fixed the issue with ECL. The package definition, being in boot.lsp, was not compiled into into an object file for ECL's |
Trying it out on my machine and it works as advertised. It's a little awkward to work between packages though: if I define a function in Ideally, we'd be able to do casing on a per-namespace basis, not on a per-evaluation-method basis. Can we make something like that work? Instead of upper-casing entire expressions, can we qualify specific symbols (those starting with |
Also, are both |
As far as the justification for both load and eval, load allows you to treat the string as a separate file, including the ability to The idea to evaluate As it stands the EDIT: Also I am not sure how to escape the |
I don't know if doing casing on a per-package basis is feasible. I'm considering merging this as-is. @tizoc thoughts? |
@Drainful character escape sequence in Shen looks like So the escape sequence for |
I created a new package The only way to dynamically change casing within a file would be with a reader macro. I might get around to doing that eventually, but the current situation is workable. I would like to (slowly) begin work on creating a loadable ASDF system to allow the embedding of Shen code in programs with a Lisp entry point, though that should probably be a separate pull request. |
@Drainful I'm going to go ahead and merge. Thanks for all your work on this! |
Fixes #24
This is an attempt at easing interoperability between Shen and Lisp. I began by putting all Lisp code (including the output of translated K Lambda, and the top level REPL) into a separate package
:SHEN
. This allows external Lisp libraries to be run without accidental intersection with Shen names. Secondly, I created three functions (located in native.lsp) to more easily call Lisp code from Shen.load-lisp
, a function which loads the given Common Lisp file in theCOMMON-LISP-USER
package and in the:UPCASE
readtable case.load-inline-lisp
, which loads Lisp from a string as an input stream under the same conditions as load-lisp.eval-inline-lisp
, which evaluates a lisp form from a string and returns its value under the same conditions as load-lisp.I believe that these changes will vastly improve the ability of Shen to interoperate with Common Lisp code. Please advise me on what changes if any I ought to make to this pull request.
Thank you.