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

Fix type of get_tydesc intrinsic in typeck::check::check_intrinsic_type #3730

Closed
catamorphism opened this issue Oct 11, 2012 · 4 comments
Closed
Labels
A-typesystem Area: The type system E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

Comments

@catamorphism
Copy link
Contributor

Should be *intrinsic::tydesc and not *().

graydon added a commit to graydon/rust that referenced this issue Feb 26, 2013
@catamorphism
Copy link
Contributor Author

Not critical for 0.6, de-milestoning

@bstrie
Copy link
Contributor

bstrie commented Jun 6, 2013

https://github.com/mozilla/rust/blob/incoming/src/librustc/front/intrinsic.rs#L21

    pub fn get_tydesc<T>() -> *TyDesc {
        unsafe {
            rusti::get_tydesc::<T>() as *TyDesc
        }
    }

This appears to be fixed, closing.

@bstrie bstrie closed this as completed Jun 6, 2013
@alexcrichton
Copy link
Member

I don't think this is closed. This look like the point of the issue is to get rid of the as *TyDesc cast. I could be wrong though.

@alexcrichton alexcrichton reopened this Jun 15, 2013
bors added a commit that referenced this issue Jun 24, 2013
This sets the `get_tydesc()` return type correctly and removes the intrinsic module. See #3730, #3475.

Update: this now also removes the unused shape fields in tydescs.
bors added a commit that referenced this issue Jun 25, 2013
This sets the `get_tydesc()` return type correctly and removes the intrinsic module. See #3730, #3475.

Update: this now also removes the unused shape fields in tydescs.
@emberian
Copy link
Member

emberian commented Aug 5, 2013

This has been fixed

@emberian emberian closed this as completed Aug 5, 2013
RalfJung pushed a commit to RalfJung/rust that referenced this issue Jul 29, 2024
Add `gettid` support

Add support for `gettid` in miri.

To ensure that the requirement that  `getpid() == gettdi()` for the main thread, we use the value returned by `getpid` and add to it the internal thread index.

Since `getpid` is only supported when isolation is disabled, and we want `gettid` to be used both in isolated and non-isolated executions, we modify `getpid` to return a hardcoded value (1000) when running in isolation mode.

Fixes rust-lang#3730
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-typesystem Area: The type system E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

No branches or pull requests

4 participants