Comments (8)
@nojaf fyi, might be interesting for you
from fslang-design.
If the lexer/parser can capture this in the syntax tree, Fantomas can restore it.
from fslang-design.
This can be captured, yes, we should treat this as an FCS/ fantomas bug
from fslang-design.
What's the next step then? Do I file a bug report in Fantomas, then try to fix it before v5 hits?
from fslang-design.
The next step would be to raise a PR to dotnet/fsharp
that adds the shebang as ParsedHashDirective (I think).
You can open an issue in Fantomas, but you would get the same reply there.
This doesn't hinder the v5 release, we would accept a fix at any time for this.
from fslang-design.
Actually, after taking another look at this, it can be solved quite easily on Fantomas' side without any compiler changes.
Looking at the AST, the shebang is parsed as a line comment. There is a bug in Fantomas that doesn't recognize this as a line comment on a single line because it does not start with //
.
@mataha, please report an issue on Fantomas' side. You can do this using the online tool.
from fslang-design.
@dsyme this was implemented in Fantomas a while ago, do we still need to do anything here?
from fslang-design.
This can be closed as completed.
from fslang-design.
Related Issues (20)
- [style-guide] Units of measure should format like expressions HOT 7
- [style-guide] Guidance for code quotations HOT 1
- [style-guide] when expressions in match clauses HOT 15
- [style-guide] Format mutation expressions on their own line HOT 11
- [style-guide] Formatting of argument lists HOT 27
- [style-guide] prefer leading rather than trailing operators HOT 8
- [style-guide] Chain of (fluent) calls HOT 7
- [style-guide] Multiline base constructor call HOT 2
- [style-guide] Stroustrup bracket style HOT 28
- [style-guide] Multiline type annotations HOT 5
- [style-guide] Advice on Attributes needs improving HOT 1
- [style-guide] Parameter owner patterns should be consistent with prefix application expressions HOT 10
- [style-guide] Multiline application in patterns HOT 2
- [style-guide] Breaking of complex pattern match expressions HOT 1
- [style-guide] Lambda closing paren defaults HOT 5
- [style-guide] Treat cast operators :> and :?> as pipe operators
- Bug: Compilation error when multiple interface generic types are matched using `or`.
- [style-guide]: Multiline generic type parameters bracket alignment HOT 3
- [style-guide] Single case union with private constructor and static members HOT 3
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 fslang-design.