scalar  : scalar INDENT SCALAR DEDENT
504664
def p_scalar__string_indented_multi_line(self, p):
        
        scalar = '\n'.join([p[1].value, p[3]])

        p[0] = ScalarDispatch(fold(scalar), cast='str')
1252058
def indent(text, amount, ch=' '):
    """"""
    padding = amount * ch
    return ''.join(padding+line for line in text.splitlines(True))
462914
def parse_block_scalar_empty_line(IndentTokenClass, ContentTokenClass):
    """"""
    def callback(lexer, match, context):
        text = match.group()
        if (context.block_scalar_indent is None or
                len(text) <= context.block_scalar_indent):
            if text:
                yield match.start(), IndentTokenClass, text
        else:
            indentation = text[:context.block_scalar_indent]
            content = text[context.block_scalar_indent:]
            yield match.start(), IndentTokenClass, indentation
            yield (match.start()+context.block_scalar_indent,
                    ContentTokenClass, content)
        context.pos = match.end()
    return callback
24516
function(str, indent) {
			var lines = str.split("\n");
			for (var i=0; i<lines.length; i++)
				lines[i] = indent + lines[i];
			return lines.join("\n");
		}
685519
def alphadump(d, indent=2, depth=0):
    
    sep = '\n' + ' ' * depth * indent
    return ''.join(
        ("{}: {}{}".format(
            k,
            alphadump(d[k], depth=depth+1) if isinstance(d[k], dict)
            else str(d[k]),
            sep)
         for k in sorted(d.keys()))
    )
245800
function indent(str/*: string*/, level/*: number*/ = 1) /*: string*/ {
    if (typeof str === 'number') [ level, str ] = [ str, level ];
    if (typeof level !== 'number') level = 1;
    return (str || '').replace(/^/gm, '  '.repeat(level));
}
909087
private static char[] getIndent(int indentSize, Map<Integer, char[]> indentCache) {
        char[] indent = indentCache.get(indentSize);
        if (indent == null) {
            indent = new char[indentSize];
            Arrays.fill(indent, SPACE);
            indentCache.put(indentSize, indent);
        }

        return indent;
    }
918636
def indent_list(inlist, level):
    """"""

    indent = ' '*level
    joinstr = '\n' + indent

    retval = joinstr.join(inlist)
    return indent + retval
803020
function () {
            var indentStr = '';
            for (var i = 0; i < indentLevel; i++) {
                indentStr += INDENT;
            }
            return {
                type: 'WhiteSpace',
                value: indentStr
            };
        }
837437
def determine_indentation(self):
        """"""
        # Ensuring NEWLINE tokens are actually specified as such
        if self.current.tokenum != NEWLINE and self.current.value == '\n':
            self.current.tokenum = NEWLINE

        # I want to change dedents into indents, because they seem to screw nesting up
        if self.current.tokenum == DEDENT:
            self.current.tokenum, self.current.value = self.convert_dedent()

        if self.after_space and not self.is_space and (not self.in_container or self.just_started_container):
            # Record current indentation level
            if not self.indent_amounts or self.current.scol > self.indent_amounts[-1]:
                self.indent_amounts.append(self.current.scol)

            # Adjust indent as necessary
            while self.adjust_indent_at:
                self.result[self.adjust_indent_at.pop()] = (INDENT, self.indent_type * (self.current.scol - self.groups.level))

        # Roll back groups as necessary
        if not self.is_space and not self.in_container:
            while not self.groups.root and self.groups.level >= self.current.scol:
                self.finish_hanging()
                self.groups = self.groups.parent

        # Reset indentation to deal with nesting
        if self.current.tokenum == INDENT and not self.groups.root:
           self.current.value = self.current.value[self.groups.level:]
317096
def _decreaseIndent(self, indent):
        
        if indent.endswith(self._qpartIndent()):
            return indent[:-len(self._qpartIndent())]
        else:  # oops, strange indentation, just return previous indent
            return indent
295937
def get_indent(text):
    
    indent = ''

    ret = re.match(r'(\s*)', text)
    if ret:
        indent = ret.group(1)

    return indent
1258207
def _indentUpTo(self, text, width):
        
        visibleTextWidth = self._realToVisibleColumn(text, len(text))
        diff = width - visibleTextWidth
        if diff <= 0:
            return ''
        elif self._qpart.indentUseTabs and \
           all([char == '\t' for char in text]):  # if using tabs and only tabs in text
            return '\t' * (diff // self._qpart.indentWidth) + \
                   ' ' * (diff % self._qpart.indentWidth)
        else:
            return ' ' * int(diff)
889784
def reset_indent(token_class):
        """"""
        def callback(lexer, match, context):
            text = match.group()
            context.indent_stack = []
            context.indent = -1
            context.next_indent = 0
            context.block_scalar_indent = None
            yield match.start(), token_class, text
            context.pos = match.end()
        return callback
960850
private static void appendIndentedNewLine(int indentLevel, StringBuilder stringBuilder) {
        stringBuilder.append("\n");
        for (int i = 0; i < indentLevel; i++) {
            // Assuming indention using 2 spaces
            stringBuilder.append("  ");
        }
    }
820649
def get_line_indent(token):
    """"""
    start = token.start_mark.buffer.rfind('\n', 0,
                                          token.start_mark.pointer) + 1
    content = start
    while token.start_mark.buffer[content] == ' ':
        content += 1
    return content - start
387379
def indent(text: str, num: int = 2) -> str:
    """"""
    lines = text.splitlines()
    return "\n".join(indent_iterable(lines, num=num))