<commit_before>/*     / \____  _    ______   _____ / \____   ____  _____
 *    /  \__  \/ \  / \__  \ /  __//  \__  \ /    \/ __  \   Javaslang
 *  _/  // _\  \  \/  / _\  \\_  \/  // _\  \  /\  \__/  /   Copyright 2014-2015 <NAME>
 * /___/ \_____/\____/\_____/____/\___\_____/_/  \_/____/    Licensed under the Apache License, Version 2.0
 */
package javaslang.control;

import java.io.Serializable;
import java.util.Objects;
import java.util.Optional;
import java.util.function.Consumer;
import java.util.function.Function;

/**
 * Some represents a defined {@link javaslang.control.Option}. It contains a value which may be null. However, to
 * create an Option containing null, {@code new Some(null)} has to be called. In all other cases
 * {@link Option#of(Object)} is sufficient.
 *
 * @param <T> The type of the optional value.
 * @since 1.0.0
 */
public final class Some<T> implements Option<T>, Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * The singleton instance of {@code Some<Void>}.
     */
    public static final Some<Void> NOTHING = new Some<>(null);

    private final T value;

    /**
     * Creates a new Some containing the given value.
     *
     * @param value A value, may be null
     */
    public Some(T value) {
        this.value = value;
    }

    /**
     * Return the singleton instance of {@code Some<Void>}.
     *
     * @return {@link #NOTHING}
     */
    public static Some<Void> nothing() {
        return NOTHING;
    }

    @Override<commit_msg>Changed visibility of Some.NOTHING constant<commit_after>/*     / \____  _    ______   _____ / \____   ____  _____
 *    /  \__  \/ \  / \__  \ /  __//  \__  \ /    \/ __  \   Javaslang
 *  _/  // _\  \  \/  / _\  \\_  \/  // _\  \  /\  \__/  /   Copyright 2014-2015 <NAME>
 * /___/ \_____/\____/\_____/____/\___\_____/_/  \_/____/    Licensed under the Apache License, Version 2.0
 */
package javaslang.control;

import java.io.Serializable;
import java.util.Objects;
import java.util.Optional;
import java.util.function.Consumer;
import java.util.function.Function;

/**
 * Some represents a defined {@link javaslang.control.Option}. It contains a value which may be null. However, to
 * create an Option containing null, {@code new Some(null)} has to be called. In all other cases
 * {@link Option#of(Object)} is sufficient.
 *
 * @param <T> The type of the optional value.
 * @since 1.0.0
 */
public final class Some<T> implements Option<T>, Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * The singleton instance of {@code Some<Void>}.
     */
    private static final Some<Void> NOTHING = new Some<>(null);

    private final T value;

    /**
     * Creates a new Some containing the given value.
     *
     * @param value A value, may be null
     */
    public Some(T value) {
        this.value = value;
    }

    /**
     * Return the singleton instance of {@code Some<Void>}.
     *
     * @return {@link #NOTHING}
     */
    public static Some<Void> nothing() {
        return NOTHING;
    }

    @Override
{'fraction_non_alphanumeric': 0.13452188006482982, 'fraction_numerical': 0.00907617504051864, 'mean_word_length': 2.1683778234086244, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5313149', 'n_tokens_mistral': 1037, 'n_tokens_neox': 990, 'n_words': 277}