@@ -272,72 +272,72 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
272
272
273
273
"pthread_mutexattr_init" => {
274
274
let result = this. pthread_mutexattr_init ( args[ 0 ] ) ?;
275
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
275
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
276
276
}
277
277
278
278
"pthread_mutexattr_settype" => {
279
279
let result = this. pthread_mutexattr_settype ( args[ 0 ] , args[ 1 ] ) ?;
280
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
280
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
281
281
}
282
282
283
283
"pthread_mutexattr_destroy" => {
284
284
let result = this. pthread_mutexattr_destroy ( args[ 0 ] ) ?;
285
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
285
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
286
286
}
287
287
288
288
"pthread_mutex_init" => {
289
289
let result = this. pthread_mutex_init ( args[ 0 ] , args[ 1 ] ) ?;
290
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
290
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
291
291
}
292
292
293
293
"pthread_mutex_lock" => {
294
294
let result = this. pthread_mutex_lock ( args[ 0 ] ) ?;
295
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
295
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
296
296
}
297
297
298
298
"pthread_mutex_trylock" => {
299
299
let result = this. pthread_mutex_trylock ( args[ 0 ] ) ?;
300
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
300
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
301
301
}
302
302
303
303
"pthread_mutex_unlock" => {
304
304
let result = this. pthread_mutex_unlock ( args[ 0 ] ) ?;
305
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
305
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
306
306
}
307
307
308
308
"pthread_mutex_destroy" => {
309
309
let result = this. pthread_mutex_destroy ( args[ 0 ] ) ?;
310
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
310
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
311
311
}
312
312
313
313
"pthread_rwlock_rdlock" => {
314
314
let result = this. pthread_rwlock_rdlock ( args[ 0 ] ) ?;
315
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
315
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
316
316
}
317
317
318
318
"pthread_rwlock_tryrdlock" => {
319
319
let result = this. pthread_rwlock_tryrdlock ( args[ 0 ] ) ?;
320
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
320
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
321
321
}
322
322
323
323
"pthread_rwlock_wrlock" => {
324
324
let result = this. pthread_rwlock_wrlock ( args[ 0 ] ) ?;
325
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
325
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
326
326
}
327
327
328
328
"pthread_rwlock_trywrlock" => {
329
329
let result = this. pthread_rwlock_trywrlock ( args[ 0 ] ) ?;
330
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
330
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
331
331
}
332
332
333
333
"pthread_rwlock_unlock" => {
334
334
let result = this. pthread_rwlock_unlock ( args[ 0 ] ) ?;
335
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
335
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
336
336
}
337
337
338
338
"pthread_rwlock_destroy" => {
339
339
let result = this. pthread_rwlock_destroy ( args[ 0 ] ) ?;
340
- this. write_scalar ( Scalar :: from_int ( result, dest . layout . size ) , dest) ?;
340
+ this. write_scalar ( Scalar :: from_i32 ( result) , dest) ?;
341
341
}
342
342
343
343
| "signal"
0 commit comments