Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typos #1053

Open
wants to merge 1 commit into
base: v3
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion decode_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1485,7 +1485,7 @@ func (s *S) TestMergeNestedStruct(c *C) {
//
// Quick summary of the fields:
//
// - A must come from outer and not overriden
// - A must come from outer and not overridden
// - B must not be set as its in the ignored merge
// - C should still be set as it's preset in the value
// - D should be set from the recursive merge
Expand Down
8 changes: 4 additions & 4 deletions scannerc.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ import (
// %TAG !yaml! tag:yaml.org,2002:
// ---
//
// The correspoding sequence of tokens:
// The corresponding sequence of tokens:
//
// STREAM-START(utf-8)
// VERSION-DIRECTIVE(1,1)
Expand Down Expand Up @@ -300,7 +300,7 @@ import (
// The tokens BLOCK-SEQUENCE-START and BLOCK-MAPPING-START denote indentation
// increase that precedes a block collection (cf. the INDENT token in Python).
// The token BLOCK-END denote indentation decrease that ends a block collection
// (cf. the DEDENT token in Python). However YAML has some syntax pecularities
// (cf. the DEDENT token in Python). However YAML has some syntax peculiarities
// that makes detections of these tokens more complex.
//
// The tokens BLOCK-ENTRY, KEY, and VALUE are used to represent the indicators
Expand Down Expand Up @@ -1332,7 +1332,7 @@ func yaml_parser_fetch_key(parser *yaml_parser_t) bool {

// In the block context, additional checks are required.
if parser.flow_level == 0 {
// Check if we are allowed to start a new key (not nessesary simple).
// Check if we are allowed to start a new key (not necessary simple).
if !parser.simple_key_allowed {
return yaml_parser_set_scanner_error(parser, "", parser.mark,
"mapping keys are not allowed in this context")
Expand Down Expand Up @@ -2563,7 +2563,7 @@ func yaml_parser_scan_flow_scalar(parser *yaml_parser_t, token *yaml_token_t, si
for k := 0; k < code_length; k++ {
if !is_hex(parser.buffer, parser.buffer_pos+k) {
yaml_parser_set_scanner_error(parser, "while parsing a quoted scalar",
start_mark, "did not find expected hexdecimal number")
start_mark, "did not find expected hexadecimal number")
return false
}
value = (value << 4) + as_hex(parser.buffer, parser.buffer_pos+k)
Expand Down
8 changes: 4 additions & 4 deletions yaml.go
Original file line number Diff line number Diff line change
Expand Up @@ -347,9 +347,9 @@ const (
// control over the content being decoded or encoded.
//
// It's worth noting that although Node offers access into details such as
// line numbers, colums, and comments, the content when re-encoded will not
// line numbers, columns, and comments, the content when re-encoded will not
// have its original textual representation preserved. An effort is made to
// render the data plesantly, and to preserve comments near the data they
// render the data pleasantly, and to preserve comments near the data they
// describe, though.
//
// Values that make use of the Node type interact with the yaml package in the
Expand All @@ -375,7 +375,7 @@ type Node struct {
// scalar nodes may be obtained via the ShortTag and LongTag methods.
Kind Kind

// Style allows customizing the apperance of the node in the tree.
// Style allows customizing the appearance of the node in the tree.
Style Style

// Tag holds the YAML tag defining the data type for the value.
Expand All @@ -387,7 +387,7 @@ type Node struct {
// the implicit tag diverges from the provided one.
Tag string

// Value holds the unescaped and unquoted represenation of the value.
// Value holds the unescaped and unquoted representation of the value.
Value string

// Anchor holds the anchor name for this node, which allows aliases to point to it.
Expand Down
2 changes: 1 addition & 1 deletion yamlh.go
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,7 @@ type yaml_emitter_t struct {
scalar_data struct {
value []byte // The scalar value.
multiline bool // Does the scalar contain line breaks?
flow_plain_allowed bool // Can the scalar be expessed in the flow plain style?
flow_plain_allowed bool // Can the scalar be expressed in the flow plain style?
block_plain_allowed bool // Can the scalar be expressed in the block plain style?
single_quoted_allowed bool // Can the scalar be expressed in the single quoted style?
block_allowed bool // Can the scalar be expressed in the literal or folded styles?
Expand Down