Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stack overflow when using fantomas 3.2.0-beta-002 #630

Closed
SteveGilham opened this issue Jan 10, 2020 · 4 comments
Closed

Stack overflow when using fantomas 3.2.0-beta-002 #630

SteveGilham opened this issue Jan 10, 2020 · 4 comments

Comments

@SteveGilham
Copy link

SteveGilham commented Jan 10, 2020

Description

Formatting this source file with this configuration

{
  "IndentSpaceNum":2,
  "PageWidth":90,
  "SemicolonAtEndOfLine":false,
  "SpaceBeforeArgument":true ,
  "SpaceBeforeColon":false,
  "SpaceAfterComma":true ,
  "SpaceAfterSemicolon":true ,
  "IndentOnTryWith":false,
  "ReorderOpenDeclaration":false,
  "SpaceAroundDelimiter":true ,
  "KeepNewlineAfter":false,
  "MaxIfThenElseShortWidth":40,
  "StrictMode":false
}

fails with stack overflow.

Also, this .fsx file with no #if clauses

Repro code

Repro given above; the source file is too large as it stands to use the online tool.

@SteveGilham
Copy link
Author

This is on Windows, so possibly not a duplicate of #591

@nojaf nojaf mentioned this issue Feb 18, 2020
@nojaf
Copy link
Contributor

nojaf commented Feb 18, 2020

Could you please try https://www.nuget.org/packages/fantomas-tool/3.3.0-beta-001 and see if the performance issue still occurs?

@SteveGilham
Copy link
Author

With the new build, the formatting operation completes, though the output does include many instances of #if directives being doubled. I shall see if I can get a cut-down example to submit separately.

@nojaf
Copy link
Contributor

nojaf commented Feb 18, 2020

Yes, I haven't been able to resolve the #if problems 😔.
Please open new issues with the online tool: https://jindraivanek.gitlab.io/fantomas-ui/#?fantomas=preview
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants