function build_class_directives_object(class_directives, expressions, context) {
	let properties = [];
	let has_call_or_state = false;

	for (const d of class_directives) {
		const expression = /** @type Expression */ (context.visit(d.expression));
		properties.push(b.init(d.name, expression));
		has_call_or_state ||= d.metadata.expression.has_call || d.metadata.expression.has_state;
	}

	const directives = b.object(properties);

	return has_call_or_state ? get_expression_id(expressions, directives) : directives;
}
@param {AST.ClassDirective[]} class_directives
@param {Expression[]} expressions
@param {ComponentContext} context
@return {ObjectExpression | Identifier}