Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for FOpen (0.04 sec)

  1. src/cmd/cgo/internal/swig/testdata/stdio/main.go

    func main() {
    	if x := int(C.F()); x != 1 {
    		fatal("x = %d, want 1", x)
    	}
    
    	// Open this file itself and verify that the first few characters are
    	// as expected.
    	f := Fopen("main.go", "r")
    	if f.Swigcptr() == 0 {
    		fatal("fopen failed")
    	}
    	if Fgetc(f) != '/' || Fgetc(f) != '/' || Fgetc(f) != ' ' || Fgetc(f) != 'C' {
    		fatal("read unexpected characters")
    	}
    	if Fclose(f) != 0 {
    		fatal("fclose failed")
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:07 UTC 2023
    - 975 bytes
    - Viewed (0)
  2. src/cmd/cgo/internal/swig/testdata/stdio/main.swig

    %typemap(gotype) const char * "string"
    %typemap(in) const char * %{
    	$1 = malloc($input.n + 1);
    	memcpy($1, $input.p, $input.n);
    	$1[$input.n] = '\0';
    %}
    %typemap(freearg) const char * %{
    	free($1);
    %}
    
    FILE *fopen(const char *name, const char *mode);
    int fclose(FILE *);
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:07 UTC 2023
    - 563 bytes
    - Viewed (0)
  3. src/cmd/cgo/internal/testerrors/testdata/err2.go

    	x := (*C.bar_t)(nil)
    	C.foop = x // ERROR HERE
    
    	// issue 13129: used to output error about C.unsignedshort with CC=clang
    	var x1 C.ushort
    	x1 = int(0) // ERROR HERE: C\.ushort
    
    	// issue 13423
    	_ = C.fopen() // ERROR HERE
    
    	// issue 13467
    	var x2 rune = '✈'
    	var _ rune = C.transform(x2) // ERROR HERE: C\.int
    
    	// issue 13635: used to output error about C.unsignedchar.
    	// This test tests all such types.
    	var (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 11:59:56 UTC 2023
    - 2.5K bytes
    - Viewed (0)
  4. tensorflow/c/experimental/filesystem/plugins/gcs/cleanup.h

    // capturing the return value in an 'auto' local variable. Most users will not
    // need more sophisticated syntax than that.
    //
    // Example:
    //   void func() {
    //     FILE* fp = fopen("data.txt", "r");
    //     if (fp == nullptr) return;
    //     auto fp_cleaner = gtl::MakeCleanup([fp] { fclose(fp); });
    //     // No matter what, fclose(fp) will happen.
    //     DataObject d;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jul 09 11:16:00 UTC 2020
    - 3.4K bytes
    - Viewed (0)
  5. tensorflow/c/experimental/filesystem/plugins/posix/posix_filesystem.cc

      TF_SetStatus(status, TF_OK, "");
    }
    
    static void NewWritableFile(const TF_Filesystem* filesystem, const char* path,
                                TF_WritableFile* file, TF_Status* status) {
      FILE* f = fopen(path, "w");
      if (f == nullptr) {
        TF_SetStatusFromIOError(status, errno, path);
        return;
      }
    
      file->plugin_file = new tf_writable_file::PosixFile({strdup(path), f});
      TF_SetStatus(status, TF_OK, "");
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Mar 24 20:08:23 UTC 2024
    - 15.8K bytes
    - Viewed (0)
  6. src/cmd/cgo/internal/test/test.go

    }
    
    func testErrno(t *testing.T) {
    	p := C.CString("no-such-file")
    	m := C.CString("r")
    	f, err := C.fopen(p, m)
    	C.free(unsafe.Pointer(p))
    	C.free(unsafe.Pointer(m))
    	if err == nil {
    		C.fclose(f)
    		t.Fatalf("C.fopen: should fail")
    	}
    	if err != syscall.ENOENT {
    		t.Fatalf("C.fopen: unexpected error: %v", err)
    	}
    }
    
    func testMultipleAssign(t *testing.T) {
    	p := C.CString("234")
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 20 15:50:06 UTC 2024
    - 48.5K bytes
    - Viewed (0)
  7. testing/performance/src/templates/native-dependents-resources/googleTest/libs/googleTest/1.7.0/include/gtest/internal/gtest-port.h

    // defined there.
    
    #if !GTEST_OS_WINDOWS_MOBILE
    inline int ChDir(const char* dir) { return chdir(dir); }
    #endif
    inline FILE* FOpen(const char* path, const char* mode) {
      return fopen(path, mode);
    }
    #if !GTEST_OS_WINDOWS_MOBILE
    inline FILE *FReopen(const char* path, const char* mode, FILE* stream) {
      return freopen(path, mode, stream);
    }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 67.2K bytes
    - Viewed (0)
  8. platforms/documentation/docs/src/snippets/native-binaries/google-test/groovy/libs/googleTest/1.7.0/include/gtest/internal/gtest-port.h

    // defined there.
    
    #if !GTEST_OS_WINDOWS_MOBILE
    inline int ChDir(const char* dir) { return chdir(dir); }
    #endif
    inline FILE* FOpen(const char* path, const char* mode) {
      return fopen(path, mode);
    }
    #if !GTEST_OS_WINDOWS_MOBILE
    inline FILE *FReopen(const char* path, const char* mode, FILE* stream) {
      return freopen(path, mode, stream);
    }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Nov 27 17:53:42 UTC 2023
    - 67.2K bytes
    - Viewed (0)
  9. src/regexp/testdata/testregex.c

    	while (state.file = *argv++)
    	{
    		if (streq(state.file, "-") || streq(state.file, "/dev/stdin") || streq(state.file, "/dev/fd/0"))
    		{
    			state.file = 0;
    			fp = stdin;
    		}
    		else if (!(fp = fopen(state.file, "r")))
    		{
    			fprintf(stderr, "%s: %s: cannot read\n", unit, state.file);
    			return 2;
    		}
    		testno = state.errors = state.ignored = state.lineno = state.passed =
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Sep 08 04:08:51 UTC 2014
    - 51.3K bytes
    - Viewed (0)
Back to top