Skip to content

Commit

Permalink
address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-zli committed Jan 3, 2024
1 parent 69c1cfa commit 29b33fd
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ private[snowpark] trait LeafNode extends LogicalPlan {
// create ExpressionAnalyzer with empty alias map
override protected val analyzer: ExpressionAnalyzer = ExpressionAnalyzer()

override lazy val dfAliasMap: Map[String, Seq[Attribute]] = Map.empty

// leaf node doesn't have child
override def updateChildren(func: LogicalPlan => LogicalPlan): LogicalPlan = this

Expand Down Expand Up @@ -202,9 +200,8 @@ private[snowpark] case class DataframeAlias(alias: String, child: LogicalPlan)

override lazy val dfAliasMap: Map[String, Seq[Attribute]] =
Utils.addToDataframeAliasMap(Map(alias -> child.getSnowflakePlan.get.output), child)
override protected def createFromAnalyzedChild: LogicalPlan => LogicalPlan = child => {
DataframeAlias(alias, child)
}
override protected def createFromAnalyzedChild: LogicalPlan => LogicalPlan =
DataframeAlias(alias, _)

override protected def updateChild: LogicalPlan => LogicalPlan =
createFromAnalyzedChild
Expand Down

0 comments on commit 29b33fd

Please sign in to comment.