question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

extra namespace added when -Namespace has two dots

See original GitHub issue

So if I call autorest -input swagger.json -Namespace a.b.c the generated classes will have a new using included that says using a.b

whenever -namespace parameter has two dots, autorest will add a new using for the two words before the second dot. which I believe is not the correct behavior

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
fearthecowboycommented, May 1, 2017

The using a.b; is added by the Roslyn Code Fixer/simplifier.

I’m not sure that there’s anything that I can do in the immediate term; is this causing some sort of problem?

1reaction
fearthecowboycommented, Mar 30, 2017

Ah yeah. That’s a side-effect of the Roslyn-based c# simplifier.

Hmm.

We’ll have to see if we can stop that. I dunno why it wants to do that.

G

Read more comments on GitHub >

github_iconTop Results From Across the Web

Is there a better way to express nested namespaces in C++ ...
I think Microsoft's usage of namespaces makes sense and it is indeed deeper than just 2 Levels. I think bigger libraries / projects...
Read more >
Change default namespace associated to a folder when ...
And any file added to that folder will have the namespace based on the override when file is created. And this should only...
Read more >
Managing Namespaces in an XML Document - Microsoft Learn
When you use multiple namespaces in an XML document, you can define one namespace as the default namespace to create a cleaner looking...
Read more >
Building containers by hand using namespaces: The net ...
Example 1: Configure point-to-point net namespaces. The first example is creating two net namespaces that communicate with each other.
Read more >
C# Namespaces [With Examples] - Programiz
Two or more classes when put into different namespaces can have same name. ... The members of a namespace can be accessed using...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found