flag,json,net: handle C calls in .v files (part of enabling -W impure-v as default) (#19779)

This commit is contained in:
JalonSolov 2023-11-06 07:27:00 -05:00 committed by GitHub
parent 1e25d45243
commit 01022e918e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
21 changed files with 50 additions and 50 deletions

View file

@ -0,0 +1,17 @@
import net.openssl
struct Abc {
x &C.SSL_CTX
}
fn test_printing_struct_with_reference_field_of_type_ssl_ctx() {
a := unsafe { Abc{&C.SSL_CTX(123)} }
dump(a)
sa := a.str()
assert sa.contains('&C.SSL_CTX(0x7b)')
}
fn test_openssl_compiles() {
assert openssl.is_used == 1
assert true
}