Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 5,408 for copyFn (0.15 sec)

  1. pkg/file/file_test.go

    	"path/filepath"
    	"testing"
    
    	"istio.io/istio/pkg/test/util/assert"
    )
    
    func copyTest(t *testing.T, copyFn func(srcFilepath, targetDir, targetFilename string) error) {
    	t.Helper()
    	d := t.TempDir()
    	if err := os.WriteFile(filepath.Join(d, "in"), []byte("hello world"), 0o750); err != nil {
    		t.Fatal(err)
    	}
    	if err := copyFn(filepath.Join(d, "in"), d, "out"); err != nil {
    		t.Fatal(err)
    	}
    	f, err := os.Open(filepath.Join(d, "out"))
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Dec 11 19:10:54 UTC 2023
    - 1.9K bytes
    - Viewed (0)
  2. test/noinit.go

    	// make this special case work.
    
    	copy_four, copy_five = four, five
    	copy_x               = x
    	// copy_y = y // static init of copied strings defeats link -X; see #34675
    	copy_nilslice = nilslice
    	copy_nilmap   = nilmap
    	copy_nilfunc  = nilfunc
    	copy_nilchan  = nilchan
    	copy_nilptr   = nilptr
    )
    
    var copy_a = a
    var copy_s = s
    var copy_c = c
    
    var copy_aa = aa
    var copy_as = as
    
    var copy_sa = sa
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 14 17:57:36 UTC 2023
    - 6.8K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/test/testdata/gen/copyGen.go

    package main
    
    import (
    	"bytes"
    	"fmt"
    	"go/format"
    	"log"
    	"os"
    )
    
    // This program generates tests to verify that copying operations
    // copy the data they are supposed to and clobber no adjacent values.
    
    // run as `go run copyGen.go`.  A file called copy.go
    // will be written into the parent directory containing the tests.
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Sep 20 02:13:02 UTC 2022
    - 3.6K bytes
    - Viewed (0)
  4. licenses/github.com/alecthomas/participle/v2/COPYING

    Copyright (C) 2017-2022 Alec Thomas
    
    Permission is hereby granted, free of charge, to any person obtaining a copy of
    this software and associated documentation files (the "Software"), to deal in
    the Software without restriction, including without limitation the rights to
    use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
    of the Software, and to permit persons to whom the Software is furnished to do
    so, subject to the following conditions:
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Apr 08 17:05:56 UTC 2024
    - 1K bytes
    - Viewed (0)
  5. cmd/kubeadm/app/util/copy.go

    		// In this case, the file is moved by copying and then deleting the source file,
    		// although it is less efficient than os.Rename().
    		klog.V(4).Infof("cannot rename %v to %v due to %v, attempting an alternative method", src, dest, err)
    		if err := CopyFile(src, dest); err != nil {
    			return errors.Wrapf(err, "failed to copy file %v to %v", src, dest)
    		}
    		return os.Remove(src)
    	}
    	return err
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Feb 22 01:42:57 UTC 2024
    - 1.9K bytes
    - Viewed (0)
  6. guava/src/com/google/common/collect/SparseImmutableTable.java

        // Casts without copying.
        ImmutableMap<C, ImmutableMap<R, V>> columnMap = this.columnMap;
        return ImmutableMap.<C, Map<R, V>>copyOf(columnMap);
      }
    
      @Override
      public ImmutableMap<R, Map<C, V>> rowMap() {
        // Casts without copying.
        ImmutableMap<R, ImmutableMap<C, V>> rowMap = this.rowMap;
        return ImmutableMap.<R, Map<C, V>>copyOf(rowMap);
      }
    
      @Override
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Nov 30 21:54:06 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  7. subprojects/core/src/main/java/org/gradle/api/tasks/Copy.java

     */
    
    package org.gradle.api.tasks;
    
    import org.gradle.api.InvalidUserDataException;
    import org.gradle.api.internal.file.copy.CopyAction;
    import org.gradle.api.internal.file.copy.CopySpecInternal;
    import org.gradle.api.internal.file.copy.DestinationRootCopySpec;
    import org.gradle.api.internal.file.copy.FileCopyAction;
    import org.gradle.work.DisableCachingByDefault;
    
    import java.io.File;
    
    /**
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Oct 24 23:13:41 UTC 2022
    - 3.4K bytes
    - Viewed (0)
  8. test/codegen/copy.go

    	// ppc64x:-".*memmove"
    	copy(x[1:], x[:])
    }
    
    func movesmall7() {
    	x := [...]byte{1, 2, 3, 4, 5, 6, 7}
    	// 386:-".*memmove"
    	// amd64:-".*memmove"
    	// arm64:-".*memmove"
    	// ppc64x:-".*memmove"
    	copy(x[1:], x[:])
    }
    
    func movesmall16() {
    	x := [...]byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16}
    	// amd64:-".*memmove"
    	// ppc64x:".*memmove"
    	copy(x[1:], x[:])
    }
    
    var x [256]byte
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 22 14:09:29 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/ir/copy.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package ir
    
    import (
    	"cmd/internal/src"
    )
    
    // Copy returns a shallow copy of n.
    func Copy(n Node) Node {
    	return n.copy()
    }
    
    // DeepCopy returns a “deep” copy of n, with its entire structure copied
    // (except for shared nodes like ONAME, ONONAME, OLITERAL, and OTYPE).
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 08 18:57:57 UTC 2023
    - 1K bytes
    - Viewed (0)
  10. src/internal/trace/batch.go

    	}
    
    	// Copy out the batch for later processing.
    	var data bytes.Buffer
    	data.Grow(int(size))
    	n, err := io.CopyN(&data, r, int64(size))
    	if n != int64(size) {
    		return batch{}, gen, fmt.Errorf("failed to read full batch: read %d but wanted %d", n, size)
    	}
    	if err != nil {
    		return batch{}, gen, fmt.Errorf("copying batch data: %w", err)
    	}
    
    	// Return the batch.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 2.9K bytes
    - Viewed (0)
Back to top