RBParser parseMethod: '...'
parses a method
RBParser parseExpression: '...'
does it for an expression
But I think both of them return a method node? I cannot recall.
However, you can always do at the end
node methodNode statements last isBlockNode
or something like that. Can't you?
On Su
Hi Mariano,
_,,,^..^,,,_ (phone)
> On Jul 24, 2017, at 9:21 AM, Mariano Martinez Peck
> wrote:
>
> Hi guys,
>
> Is there a portable (that would work in GemStone too) and safe way to know if
> a String would be a block?
>
> I must support this kind of strings:
>
> 'singleString' -> false
Presumably, you must parse the string (not evaluate), obtain an Abstract
Syntax Tree on return (or an Exception), and check that this AST conforms
to some pattern (at worse you code naïvly the pattern matching, at best you
can reuse the refactor/rewrite engine).
I've not followed latest Compiler d