Skip to content

Conversation

@jkoritzinsky
Copy link
Member

Fixes #55950.

Also remove an unused and undefined method from the CoreLib/EE interface

@elinor-fung
Copy link
Member

elinor-fung commented Aug 8, 2024

Doesn't the normal (non-extended) check also need to be updated? OffsetAndSizes doesn't handle BEGIN/END_ILLINK_FEATURE_SWITCH, so CoreLibBinder::Check would fail trying to find the classes or fields?

const CoreLibBinder::OffsetAndSizeCheck CoreLibBinder::OffsetsAndSizes[] =
{
#define DEFINE_CLASS_U(nameSpace, stringName, unmanagedType) \
{ PTR_CSTR((TADDR) g_ ## nameSpace ## NS ), PTR_CUTF8((TADDR) # stringName), sizeof(unmanagedType), 0, 0, 0 },
#define DEFINE_FIELD_U(stringName, unmanagedContainingType, unmanagedOffset) \
{ 0, 0, 0, PTR_CUTF8((TADDR) # stringName), offsetof(unmanagedContainingType, unmanagedOffset), sizeof(((unmanagedContainingType*)1)->unmanagedOffset) },
#include "corelib.h"
};

@jkoritzinsky
Copy link
Member Author

You're right! I've pushed an update with support in the regular Check method as well.

@jkoritzinsky jkoritzinsky merged commit 8fe777f into dotnet:main Aug 9, 2024
@jkoritzinsky jkoritzinsky deleted the extended-check-illink-feature-switch branch August 9, 2024 21:03
@github-actions github-actions bot locked and limited conversation to collaborators Sep 9, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BEGIN_ILLINK_FEATURE_SWITCH mechanism for corelib.h does not work with checked/debug runtime and a trimmed app

2 participants