Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 360 for escapers (2.4 sec)

  1. src/html/template/escape.go

    						s[i] = idNode.Ident
    						dup = true
    					}
    				}
    				if dup {
    					// The predefined escaper will already be inserted along with the
    					// escapers in s, so do not copy it to the rewritten pipeline.
    					pipelineLen--
    				}
    			}
    		}
    	}
    	// Rewrite the pipeline, creating the escapers in s at the end of the pipeline.
    	newCmds := make([]*parse.CommandNode, pipelineLen, pipelineLen+len(s))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 02 15:18:39 UTC 2023
    - 32.4K bytes
    - Viewed (0)
  2. src/html/template/error.go

    	//   pipeline output in Go 1.8 and earlier.
    	//
    	//   In most cases, such as the given example, this error can be resolved by
    	//   simply removing the predefined escaper from the pipeline and letting the
    	//   contextual autoescaper handle the escaping of the pipeline. In other
    	//   instances, where the predefined escaper occurs in the middle of a
    	//   pipeline where subsequent commands expect escaped input, e.g.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 02 15:18:39 UTC 2023
    - 9.3K bytes
    - Viewed (0)
  3. src/html/template/escape_test.go

    			".X | (print 12 | println).x | urlquery | html",
    			[]string{"urlquery", "html"},
    		},
    		// The following test cases ensure that the merging of internal escapers
    		// with the predefined "html" and "urlquery" escapers is correct.
    		{
    			"{{.X | urlquery}}",
    			".X | _html_template_urlfilter | urlquery",
    			[]string{"_html_template_urlfilter", "_html_template_urlnormalizer"},
    		},
    		{
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 16 03:29:27 UTC 2023
    - 56.2K bytes
    - Viewed (0)
  4. test/escape2.go

    }
    
    func foo76f() {
    	for {
    		// TODO: This one really only escapes its scope, but we don't distinguish yet.
    		defer myprint(nil, 1, 2, 3) // ERROR "... argument does not escape$" "1 escapes to heap$" "2 escapes to heap$" "3 escapes to heap$"
    	}
    }
    
    func foo76g() {
    	for {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Dec 14 17:22:18 UTC 2023
    - 35.1K bytes
    - Viewed (0)
  5. test/escape2n.go

    }
    
    func foo76f() {
    	for {
    		// TODO: This one really only escapes its scope, but we don't distinguish yet.
    		defer myprint(nil, 1, 2, 3) // ERROR "... argument does not escape$" "1 escapes to heap$" "2 escapes to heap$" "3 escapes to heap$"
    	}
    }
    
    func foo76g() {
    	for {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Dec 14 17:22:18 UTC 2023
    - 35.1K bytes
    - Viewed (0)
  6. test/escape4.go

    	f = func() { // ERROR "func literal escapes to heap" "can inline f1.func2"
    		p = alloc(3) // ERROR "inlining call to alloc" "moved to heap: x"
    	}
    	f()
    }
    
    func f2() {} // ERROR "can inline f2"
    
    // No inline for recover; panic now allowed to inline.
    func f3() { panic(1) } // ERROR "can inline f3" "1 escapes to heap"
    func f4() { recover() }
    
    func f5() *byte { // ERROR "can inline f5"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Sep 14 19:43:26 UTC 2023
    - 1.4K bytes
    - Viewed (0)
  7. test/escape5.go

    	f8(&j)
    }
    
    func f10() {
    	// These don't escape but are too big for the stack
    	var x [1 << 30]byte         // ERROR "moved to heap: x"
    	var y = make([]byte, 1<<30) // ERROR "make\(\[\]byte, 1073741824\) escapes to heap"
    	_ = x[0] + y[0]
    }
    
    // Test for issue 19687 (passing to unnamed parameters does not escape).
    func f11(**int) {
    }
    func f12(_ **int) {
    }
    func f13() {
    	var x *int
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 08 18:50:24 UTC 2023
    - 5.3K bytes
    - Viewed (0)
  8. src/html/template/template.go

    	}
    	t.nameSpace.mu.Lock()
    	defer t.nameSpace.mu.Unlock()
    	if t.nameSpace.escaped {
    		return fmt.Errorf("html/template: cannot Parse after Execute")
    	}
    	return nil
    }
    
    // escape escapes all associated templates.
    func (t *Template) escape() error {
    	t.nameSpace.mu.Lock()
    	defer t.nameSpace.mu.Unlock()
    	t.nameSpace.escaped = true
    	if t.escapeErr == nil {
    		if t.Tree == nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 21:00:46 UTC 2024
    - 17K bytes
    - Viewed (0)
  9. src/internal/abi/escape.go

    //go:nosplit
    //go:nocheckptr
    func NoEscape(p unsafe.Pointer) unsafe.Pointer {
    	x := uintptr(p)
    	return unsafe.Pointer(x ^ 0)
    }
    
    var alwaysFalse bool
    var escapeSink any
    
    // Escape forces any pointers in x to escape to the heap.
    func Escape[T any](x T) T {
    	if alwaysFalse {
    		escapeSink = x
    	}
    	return x
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 18 21:25:11 UTC 2024
    - 884 bytes
    - Viewed (0)
  10. src/main/java/org/codelibs/core/text/JsonUtil.java

     *
     */
    public class JsonUtil {
    
        /**
         * Defualt constructor.
         */
        protected JsonUtil() {
        }
    
        /**
         * Escapes a value as Json string.
         *
         * @param value input
         * @return escaped string.
         */
        public static String escape(final String value) {
            if (value == null) {
                return null;
            }
    
            char c;
            final int len = value.length();
    Registered: Wed Jun 12 12:50:12 UTC 2024
    - Last Modified: Thu Mar 07 01:59:08 UTC 2024
    - 2.3K bytes
    - Viewed (0)
Back to top