Reputation: 355
I would like to know how Rascal can read Java comments like this:
//This intent is used to share the picture between Android applications
Intent shareIntent = new Intent();
Or this:
/**
* This method can be called to share the picture between Android Applications
*/
private void shareImage() {
...
}
The method createAstFromFile seems to skip these comments.
Thanks in advance.
Upvotes: 1
Views: 331
Reputation: 6696
Comments are not included in the ASTs, but you can get the from the M3 model using @documentation field:
anno rel[loc definition, loc comments] M3@documentation;
Upvotes: 3