Comments (9)
Even just for this feature though, if we don't get the full AST ready we can just use the lexer output for now
from pathways.
the ident
token could be a variable or a construct name. We don't know which until we're in the bowels of the parser. The parser takes the all of the tokens from the lexer at once, and returns a single data structure. I don't think the parser can (or should) cause side effects, so it can only pass the name out as part of the AST.
from pathways.
Just testing this out in iex to understand a bit more about leex and yecc will check the other parsing issue now @c-brenn. Seems like we just need to add the TokenChars
to idents assuming that idents only ever appear as construct names.
Here's some crappy iex code that gets a lot of the way
File.read!("test/fixtures/no_ddis.pml") |> to_charlist |> :pml_lexer.string |> elem(1) |> Enum.filter(fn(x) -> elem(x, 0) == :ident end
# [{:ident, 1, 'foo'}, {:ident, 2, 'bar'}, {:ident, 3, 'baz'}, {:ident, 12, 'baz2'}]
from pathways.
Exactly - TokenChars
contains the exact string matched by the lexer. After the lex/parse we can iterate over the structure to find name clashes.
from pathways.
Oh, netbeans_req_release.pml
has demonstrated to me that identifiers can just appear in requires, provides etc, what does it mean, who knows!
from pathways.
@shawa are you taking this now?
from pathways.
Sure I'll give it a lash yeah
from pathways.
from pathways.
clashes are now returned from panacea, this is just a UI change now
from pathways.
Related Issues (20)
- PML-TX Save PML to File HOT 5
- Release 1 Feedback HOT 1
- Specify a Delay HOT 5
- Identify Parallel DDIs HOT 2
- Identify Sequential DDIs HOT 2
- Mock DDI Characterisation Data
- Real DDI Mock Good-Bad Time Generator
- Real DDI Agonist-Antagonist Mock Time Generator
- Locked down versions for e2e compose
- Release 2 UI HOT 3
- improve Parser/Lexer errors
- app.js refactor HOT 1
- Tabbed UI HOT 1
- DDI line numbers
- Tab UI testing docs overhaul
- `Save PML File` documentation
- Remove warnings
- Final UI discussion HOT 1
- Final doc check
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pathways.