TODO (lwhite): This could avoid the append and do a list copy
497285
@Override
    public TextColumn copy() {
        TextColumn newCol = create(name(), size());
        int r = 0;
        for (String string : this) {
            newCol.set(r, string);
            r++;
        }
        return newCol;
    }
301297
def __append_list(append_to, value):
    """"""
    if value is not None:
        if isinstance(value, list):
            append_to.extend(value)
        else:
            append_to.append(value)
1356233
def extendlist(lst, i, value=''):
    """"""
    if i < len(lst):
        pass
    else:
        lst.extend([value, ] * (i - len(lst) + 1))
936006
private static Object saveList(List<String> list) {
        if ((list == null) || list.isEmpty()) {
            return null;
        }

        int size = list.size();

        if (size == 1) {
            return list.get(0);
        }

        return list.toArray(new String[size]);
    }
595818
function postProcessList( list )
	{
		var children = list.children,
			child,
			attrs,
			count = list.children.length,
			match,
			mergeStyle,
			styleTypeRegexp = /list-style-type:(.*?)(?:;|$)/,
			stylesFilter = CKEDITOR.plugins.pastefromword.filters.stylesFilter;

		attrs = list.attributes;
		if ( styleTypeRegexp.exec( attrs.style ) )
			return;

		for ( var i = 0; i < count; i++ )
		{
			child = children[ i ];

			if ( child.attributes.value && Number( child.attributes.value ) == i + 1 )
				delete child.attributes.value;

			match = styleTypeRegexp.exec( child.attributes.style );

			if ( match )
			{
				if ( match[ 1 ] == mergeStyle || !mergeStyle )
					mergeStyle = match[ 1 ];
				else
				{
					mergeStyle = null;
					break;
				}
			}
		}

		if ( mergeStyle )
		{
			for ( i = 0; i < count; i++ )
			{
				attrs = children[ i ].attributes;
				attrs.style && ( attrs.style = stylesFilter( [ [ 'list-style-type'] ] )( attrs.style ) || '' );
			}

			list.addStyle( 'list-style-type', mergeStyle );
		}
	}
385938
def append_to_list(self, source, start=None, hasIndex=False):
        '''
        '''
        nfy = Numberify()
        try:
            if start is None:
                if type(source) is str:
                    if hasIndex is True:
                        newList = self.get_from_indexedFile(source)
                else:
                    newList = nfy.numberify_data(source,
                                                 len(self.nameDict) + 1)
            else:
                newList = nfy.numberify_data(source, start)
            self.nameDict = dict(self.nameDict.items() + newList.items())
            self.totalCount = len(self.nameDict)
        except:
            print 'Unknown error:', exc_info()[0]
729802
def _merge_list(self, key, lst):
    
    self[key] += [x for x in lst if x not in self[key]]
569288
function copyToOut(src, out, multiFileMode) {
    try {
        fs.copySync(src, out);
        fs.statSync(out)
        return out;
    } catch (err) {
    }
}
856896
def p_print_list(p):
    
    p[0] = p[1]
    p[0].eol = (p[3] is not None)

    if p[3] is not None:
        p[0].appendChild(p[3])
1215310
def lcumsum (inlist):
    
    newlist = copy.deepcopy(inlist)
    for i in range(1,len(newlist)):
        newlist[i] = newlist[i] + newlist[i-1]
    return newlist
904812
function(list, start, end, value) {
            if (list && isArray(list.value)) {
                start = evalIndex(list, start, 1);
                end   = evalIndex(list, end, start + 2) - start;

                var copy = list.value.slice();
                value // jshint expr: true
                    ? copy.splice(start, end, value)
                    : copy.splice(start, end);
                return newLessList(copy, list.type);
            }
        }
21033
private static List<String> addToList(List<String> list, String part, boolean isTrim, boolean ignoreEmpty){
		if(isTrim){
			part = StrUtil.trim(part);
		}
		if(false == ignoreEmpty || false == part.isEmpty()){
			list.add(part);
		}
		return list;
	}
327394
public <T> File appendLines(Collection<T> list) throws IORuntimeException {
		return writeLines(list, true);
	}
730613
function concat(list, totalLength) {
  if (list.length === 0) return EMPTY_BUFFER;
  if (list.length === 1) return list[0];

  const target = Buffer.allocUnsafe(totalLength);
  let offset = 0;

  for (let i = 0; i < list.length; i++) {
    const buf = list[i];
    buf.copy(target, offset);
    offset += buf.length;
  }

  return target;
}
282486
def _render_list(self, items, empty='<pre>&lt;empty&gt;</pre>'):
    
    if not items or len(items) == 0:
      self._segments.append(empty)
      return
    self._segments.append('<ul>')
    for o in items:
      self._segments.append('<li>')
      self._segments.append(str(o))
      self._segments.append('</li>')
    self._segments.append('</ul>')
1020586
@NonNull
  public static <T> List<T> immutableCopyOf(@Nullable List<T> list) {
    if (isNullOrEmpty(list)) {
      return Collections.emptyList();
    }
    return Collections.unmodifiableList(new ArrayList<>(list));
  }
397720
protected final void append (
        ArrayList<String> list, int index, String value)
    {
        // expand the list as necessary
        while (list.size() <= index) {
            list.add("");
        }
        list.set(index, list.get(index) + value);
    }