circular-dependency

Forward declarations in C++ modules (MSVC)

独自空忆成欢 提交于 2020-08-22 15:12:22
问题 I have been experimenting with modules implementation as provided by the MSVC lately and I've run into an interesting scenario. I have two classes that have a mutual dependency in their interfaces, which means that I'll have to use forward declarations to get it to compile. The following code shows an example: Module interface export module FooBar; export namespace FooBar { class Bar; class Foo { public: Bar createBar(); }; class Bar { public: Foo createFoo(); }; } Module implementation

Python: circular imports needed for type checking

徘徊边缘 提交于 2020-07-04 12:50:31
问题 First of all: I do know that there are already many questions and answers to the topic of the circular imports. The answer is more or less: "Design your Module/Class structure properly and you will not need circular imports". That is true. I tried very hard to make a proper design for my current project, I in my opinion I was successful with this. But my specific problem is the following: I need a type check in a module that is already imported by the module containing the class to check

Which locations on a handheld device are used by installed .exes for their dependent files?

主宰稳场 提交于 2020-02-06 03:40:16
问题 I have what seems to me an odd situation: an old .exe of the project on which I'm working runs on a handheld device. New versions don't (even the exact same code with no additions). Even that .exe that runs on one handheld device doesn't on the other. See this for some of the gory details. Based on this, I thought I could track down the problem. But this PC util tells me what is missing from that (PC/build machine) environment. I need to know what is missing/wrong on the CE device. So to

Which locations on a handheld device are used by installed .exes for their dependent files?

ぃ、小莉子 提交于 2020-02-06 03:40:07
问题 I have what seems to me an odd situation: an old .exe of the project on which I'm working runs on a handheld device. New versions don't (even the exact same code with no additions). Even that .exe that runs on one handheld device doesn't on the other. See this for some of the gory details. Based on this, I thought I could track down the problem. But this PC util tells me what is missing from that (PC/build machine) environment. I need to know what is missing/wrong on the CE device. So to

Angular 5: Circular dependency detected between models

旧时模样 提交于 2020-02-04 02:44:18
问题 I'm stuck for few days with this error, and I don't know how to solve it. I have 2 models in my app : User and Team . user.ts : import { Team } from './team'; export class User { id: string = null; name: string = null; email: string = null; settings: any = {}; team: Team = null; constructor(json?: Object){ var defaultSettings = {}; if(json){ this.id = json['id'] || null; this.name = json['name'] || null; this.email = json['email'] || null; this.settings = json['settings'] || {}; this.team =

Can TypeForwardedTo be used without a direct project reference?

元气小坏坏 提交于 2020-01-16 18:04:54
问题 I have two C# projects, LibraryA and LibraryB, each producing a separate DLL. LibraryA makes use of the classes in LibraryB. LibraryB needs to make a TypeForwardedTo reference to class in LibraryA. (See this question for background.) Normally, I would resolve either issue by adding a project reference, but I can't do both because VS doesn't allow circular references. The only reason I need the B-to-A reference is for the TypeForwardedTo link. I've tried using Type.GetType(string) but the

Can TypeForwardedTo be used without a direct project reference?

只谈情不闲聊 提交于 2020-01-16 18:03:40
问题 I have two C# projects, LibraryA and LibraryB, each producing a separate DLL. LibraryA makes use of the classes in LibraryB. LibraryB needs to make a TypeForwardedTo reference to class in LibraryA. (See this question for background.) Normally, I would resolve either issue by adding a project reference, but I can't do both because VS doesn't allow circular references. The only reason I need the B-to-A reference is for the TypeForwardedTo link. I've tried using Type.GetType(string) but the