charles-zablit wrote:

> I think this will add some important clarity, and will allow us to generate 
> accurate statistics about the support level of the various platforms.
> 
> How do these decorators stack?
> 
> I.e.: if I have `@requireDarwin @requireWindows` does it run (1) never, or 
> (2) on Darwin and on Windows?
> 
> What happens if I mark a test up as `@requireNonDarwin @requireWindows`, does 
> it run on Linux?

This will never run:

```py3
@requireDarwin
@requireWindows
def test():
    ...
```

This will not run on Linux, because `@requireWindows` is not satisfied.
```py3
@requireNotDarwin
@requireWindows
def test():
    ...
```

For "require Darwin or Windows", you need:
```py3
@requirePlatform(["darwin", "windows"])
def test():
    ...
```

For "require Darwin on ARM64 or Windows on ARM64", you need:
```py3
@requireARM64
@requirePlatform(["darwin", "windows"])
def test():
    ...
```


https://github.com/llvm/llvm-project/pull/212632
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to