Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

eliminate some redundancy in rt_init() - #581

Closed
WalterBright wants to merge 1 commit into
dlang:masterfrom
WalterBright:refactor-rt_init
Closed

eliminate some redundancy in rt_init()#581
WalterBright wants to merge 1 commit into
dlang:masterfrom
WalterBright:refactor-rt_init

Conversation

@WalterBright

Copy link
Copy Markdown
Member

No description provided.

Comment thread src/rt/dmain2.d

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Rethrow doesn't make sense as rt_init/rt_term is intended to be used from C.

@WalterBright

Copy link
Copy Markdown
Member Author

In general, the logic to recover from exceptions thrown during initialization needs much work. For example, when module constructors throw, as part of the recovery process, the module destructors for all the module constructors that have already succeeded need to be run.

This is just a step in that direction (I'm working on dynamic loading of DLLs).

@WalterBright

Copy link
Copy Markdown
Member Author

@dawgfoto, after much thought, it seems inevitable to me that the rt_init() code needs to be run by the calls to functions in the .ctors section.

@WalterBright

Copy link
Copy Markdown
Member Author

Obsoleted by pull #583

@WalterBright
WalterBright deleted the refactor-rt_init branch August 23, 2013 08:46
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants