Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1494)

Unified Diff: tests/ffi/ffi_timeofday_test.dart

Issue 1209033003: Work in progres, please take a look and give early feedback if this is the way we want to structure… (Closed) Base URL: git@github.com:dart-lang/fletch.git@master
Patch Set: address comments Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/ffi/ffi_test.dart ('k') | tests/io/file_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/ffi/ffi_timeofday_test.dart
diff --git a/tests/ffi/ffi_timeofday_test.dart b/tests/ffi/ffi_timeofday_test.dart
index d3aa0f7441f776581c4442d9a1093848c1e242cf..5045748e8dca53e5df2bf556a033c624e252c3a1 100644
--- a/tests/ffi/ffi_timeofday_test.dart
+++ b/tests/ffi/ffi_timeofday_test.dart
@@ -6,7 +6,7 @@ import 'dart:ffi';
import 'dart:io' as io;
import "package:expect/expect.dart";
-abstract class Timeval implements Foreign {
+abstract class Timeval implements ForeignMemory {
factory Timeval() {
switch (Foreign.bitsPerMachineWord) {
case 32: return new Timeval32();
@@ -18,19 +18,19 @@ abstract class Timeval implements Foreign {
int get tv_usec;
}
-class Timeval32 extends Foreign implements Timeval {
+class Timeval32 extends ForeignMemory implements Timeval {
Timeval32() : super.allocated(8);
int get tv_sec => getInt32(0);
int get tv_usec => getInt32(4);
}
-class Timeval64 extends Foreign implements Timeval {
+class Timeval64 extends ForeignMemory implements Timeval {
Timeval64() : super.allocated(16);
int get tv_sec => getInt64(0);
int get tv_usec => getInt64(8);
}
-final Foreign gettimeofday = Foreign.lookup('gettimeofday');
+final ForeignFunction gettimeofday = ForeignLibrary.main.lookup('gettimeofday');
main() {
Timeval timeval = new Timeval();
« no previous file with comments | « tests/ffi/ffi_test.dart ('k') | tests/io/file_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698