Skip to content

Conversation

@auduchinok
Copy link
Member

@auduchinok auduchinok commented Nov 6, 2020

Is needed for fsprojects/fantomas#1213. It seems access modifiers are always ignored for extern declarations.

@auduchinok auduchinok changed the title Keep extern declaration access Keep extern declaration access movidifer Nov 6, 2020
@auduchinok auduchinok changed the title Keep extern declaration access movidifer Keep extern declaration access modifier Nov 6, 2020
@auduchinok
Copy link
Member Author

auduchinok commented Nov 6, 2020

Well, private extern declarations are indeed not private before the fix.

Consider GetLastError:

extern UInt32 private GetLastError()

Screenshot 2020-11-06 at 21 23 15

@auduchinok auduchinok force-pushed the extern-access branch 2 times, most recently from 3dc94f9 to 08fefcf Compare November 6, 2020 20:02
@auduchinok auduchinok changed the title Keep extern declaration access modifier Fix extern declaration accessibility Nov 6, 2020
@cartermp cartermp linked an issue Nov 6, 2020 that may be closed by this pull request
Copy link
Member

@vzarytovskii vzarytovskii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@vzarytovskii vzarytovskii merged commit d35c175 into dotnet:main Nov 7, 2020
@auduchinok auduchinok deleted the extern-access branch November 7, 2020 08:52
nosami pushed a commit to xamarin/visualfsharp that referenced this pull request Feb 23, 2021
* Keep extern declaration access

* Add test

* Simplify test

* Check no modifier, explicit public modifier

* Cleanup

* Fix test
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

Successfully merging this pull request may close these issues.

Access modifier is lost in syntax tree when declaration is extern

3 participants