Created

Embed URL

HTTPS clone URL

SSH clone URL

You can clone with HTTPS or SSH.

Download Gist

simple interactive test for completing parser

View App.scala
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
object CompletingParserTestApp extends TestParser with App {
println( "Type something and hit enter" );
 
var input = ""
do {
input = readLine();
parseAll( propertyPath, input ) match {
case s : Success[Any] => println ( "valid, parsed as "+ s.get)
case MissingCompletionOrFailure( completions, msg, in)
=> if ( completions.isEmpty )
println( msg )
else {
println( "possible completions: ");
for ( c <- completions ) println( input + c )
}
}
}
while ( input != "" )
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.