@@ -204,33 +204,4 @@ module C-EXPR-FUNCTION-CALL
204
204
rule _:KResult := tv(_:CValue, T:Type => stripConstants(T))
205
205
requires fromConstantExpr(T)
206
206
207
- rule (.K => CV("EFNC2", "incompatible types in function call arguments.", "6.5.16.1:1"))
208
- ~> L:KResult := R:RValue
209
- requires type(L) =/=Type type(R) andBool ((isPointerType(type(L)) andBool notBool isPointerType(type(R))
210
- andBool notBool isNullPointerConstant(R))
211
- orBool (isArithmeticType(type(L)) andBool notBool isBoolType(type(L)))
212
- andBool notBool isArithmeticType(type(R))
213
- orBool isStructOrUnionType(type(L))
214
- andBool notBool areCompatible(stripQualifiers(type(L)), type(R))
215
- orBool isBoolType(type(L)) andBool notBool isPointerType(type(R)) andBool notBool isArithmeticType(type(R))
216
- orBool notBool (isPointerType(type(L))
217
- orBool isArithmeticType(type(L))
218
- orBool isStructOrUnionType(type(L))
219
- orBool isBoolType(type(L))))
220
- [structural] //TODO(dwightguth): this tag is needed for confluence with null pointer constants. Might want to find a better way.
221
-
222
- rule (.K => CV("EFNC3", "incompatible pointer types in function call arguments.", "6.5.16.1:1"))
223
- ~> L:KResult := R:RValue
224
- requires (isPointerType(type(L)) andBool isPointerType(type(R)))
225
- andBool notBool isVoidType(innerType(type(L)))
226
- andBool notBool isVoidType(innerType(type(R)))
227
- andBool (
228
- notBool areCompatible(
229
- stripQualifiers(stripAlignas(innerType(type(L)))),
230
- stripQualifiers(stripAlignas(innerType(type(R)))))
231
- orBool notBool (getQualifiers(innerType(type(R)))
232
- <=Set getQualifiers(innerType(type(L))))
233
- orBool getAlignas(innerType(type(L)))
234
- >Int getAlignas(innerType(type(R)))
235
- )
236
207
endmodule
0 commit comments