Hello, I have just started using JSE and am enjoying it very
much - thanks for writing it!
At the moment I just have two questions:
1) It's nice to have Fragment.getLine() so I can return things
like #{System.out.println("The line is " + ?(fr.getLine()))}
Is there also a way to get the name of the file where the
Fragment came from? I can't see anything the the
JavaDoc or in the source.
2) When I return things like
#{System.out.println("Fragment: " + ?(fr.toString()))}
I get @ and # characters in the String. Is there any
way to convert a Fragment to a String without these
characters? Again, I can't see anything obvious in the
Javadoc.
Once again, thanks for making such a lovely tool. It makes
Java programming almost as fun as Lisp or Scheme for me!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Ah, I see antlr Token has a getFileName() method. Would it be
ok if I added a call to that from Fragment (same way as getLine
is implemented) and sent you a patch?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Ah. It looks like the version of Antlr being used by jse doesn't
have the getFilename() method. I shall have to wait until jse
switches to a more up-to-date Antlr I think!
Hello, I have just started using JSE and am enjoying it very
much - thanks for writing it!
At the moment I just have two questions:
1) It's nice to have Fragment.getLine() so I can return things
like #{System.out.println("The line is " + ?(fr.getLine()))}
Is there also a way to get the name of the file where the
Fragment came from? I can't see anything the the
JavaDoc or in the source.
2) When I return things like
#{System.out.println("Fragment: " + ?(fr.toString()))}
I get @ and # characters in the String. Is there any
way to convert a Fragment to a String without these
characters? Again, I can't see anything obvious in the
Javadoc.
Once again, thanks for making such a lovely tool. It makes
Java programming almost as fun as Lisp or Scheme for me!
Ah, I see antlr Token has a getFileName() method. Would it be
ok if I added a call to that from Fragment (same way as getLine
is implemented) and sent you a patch?
Hi William,
Thanks for your interest in JSE. I would be very happy for you to make a patch to do what you describe - please send it in!
Cheers,
Tom
Ah. It looks like the version of Antlr being used by jse doesn't
have the getFilename() method. I shall have to wait until jse
switches to a more up-to-date Antlr I think!
On a more positive note, I have written my first useful jse
macro: A poor-man's step debugger! It can be found on my
home page at:
http://www.abstractnonsense.com/withDebugSExpander.jse
It's probably quite badly written, as I'm still learning jse. I would
appreciate any feedback though!